<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('修改学生课题')"/>
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-stutask-edit" th:object="${sysTaskStu}">
            <input name="id" th:field="*{id}" type="hidden">
            <div class="form-group">
                <label class="col-sm-3 control-label">课题名称：</label>
                <div class="col-sm-8">
                    <input name="taskName" th:field="*{taskName}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">课题来源：</label>
                <div class="col-sm-8">
                    <div class="radio-box" th:each="dict : ${@dict.getType('sys_task_come')}">
                        <input name="taskCome" th:field="*{taskCome}" th:id="${dict.dictCode}"
                               th:value="${dict.dictValue}" type="radio">
                        <label th:for="${dict.dictCode}" th:text="${dict.dictLabel}"></label>
                    </div>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">课题类型：</label>
                <div class="col-sm-8">
                    <div class="radio-box" th:each="dict : ${@dict.getType('sys_task_type')}">
                        <input name="taskType" th:field="*{taskType}" th:id="${dict.dictCode}"
                               th:value="${dict.dictValue}" type="radio">
                        <label th:for="${dict.dictCode}" th:text="${dict.dictLabel}"></label>
                    </div>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">课题背景：</label>
                <div class="col-sm-8">
                    <textarea class="form-control" name="taskBackground">[[*{taskBackground}]]</textarea>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">设计说明：</label>
                <div class="col-sm-8">
                    <textarea class="form-control" name="taskDesign">[[*{taskDesign}]]</textarea>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">课题技术：</label>
                <div class="col-sm-8">
                    <textarea class="form-control" name="taskTech">[[*{taskTech}]]</textarea>
                </div>
            </div>
        </form>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        var prefix = ctx + "system/stutask";
        $("#form-stutask-edit").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/edit", $('#form-stutask-edit').serialize());
            }
        }
    </script>
</body>
</html>
